package org.hawk.gwtppc.webtest.tests.constructorsuite;

import org.hawk.gwtppc.webtest.common.Asserts;
import org.hawk.gwtppc.webtest.common.Test;
import org.hawk.gwtppc.webtest.tests.mock.ClassMock;
import org.hawk.gwtppc.webtest.tests.mock.EnumMock;
import org.hawk.gwtppc.webtest.tests.mock.SubClassMock2;

public class GetDeclaringClassTest implements Test {

	public void run() throws Throwable {
		Asserts.assertEquals(SubClassMock2.class.getDeclaredConstructors()[0].getDeclaringClass(), SubClassMock2.class);
		Asserts.assertEquals(ClassMock.class.getConstructors()[0].getDeclaringClass(), ClassMock.class);
		Asserts.assertEquals(EnumMock.class.getDeclaredConstructor(String.class,int.class).getDeclaringClass(), EnumMock.class); 
	}

	public String getName() {
		return "getDeclaringClass()";
	}

}
